

import request from '@/utils/request'

export function systemConfigCheck(pram) {
  const data = {
    name: pram.name
  }
  return request({
    url: '/admin/system/config/check',
    method: 'GET',
    params: data
  })
}

export function systemConfigInfo(pram) {
  const data = {
    type: pram
  }
  return request({
    url: '/getSystemConfig',
    method: 'GET',
    params: data
  })
}

export function systemConfigSave(pram) {
  return request({
    url: '/setSystemConfig',
    method: 'POST',
    data: pram
  })
}

export function fileListApi(pram) {
  return request({
    url: '/getFileList',
    method: 'GET',
    params: pram
  })
}
export function fileImageApi(data){
  return request({
    url: '/uploadFile',
    method: 'POST',
    data
  })
}
export function fileDeleteApi(pram) {
  const _data = {
    ids:pram
  }
  return request({
    url: '/deleteFile',
    method: 'POST',
    data: _data
  })
}





/**
 * 微信上传图片
 * @param data
 */
export function wechatUploadApi(data, params) {
  return request({
    url: `/admin/wechat/media/upload`,
    method: 'post',
    data,
    params
  })
}

